set(CGM_FOUND ON)

set(CGM_VERSION "@PACKAGE_VERSION@")
set(CGM_HAS_FACET ON) # Always ON by default
set(CGM_HAS_PARALLEL @CGM_HAVE_MPI@)
set(CGM_HAS_OCC @ENABLE_OCC@)
set(PRIMARY_GEOMETRY_ENGINE "@PRIMARY_GEOMETRY_ENGINE@")

set(CGM_CPPFLAGS "@CGM_DEFINES@ @HAVE_OCC_DEF@")
set(CGM_LIB_PATH "@prefix@/lib")
set(CGM_LDFLAGS "-L${CGM_LIB_PATH} @CGM_INT_LDFLAGS@ @CGM_EXT_LDFLAGS@")
if (CGM_HAS_OCC MATCHES ON)
  set(OCC_COMMUNITY_EDITION "@ISOCE@")
  set(OCC_DIR "@OpenCascade_DIR@")
  set(OCC_VERSION "@OpenCascade_VERSION@")
  set(CGM_LDFLAGS "${CGM_LDFLAGS} -L@OCC_DIR@/lib")
  if (OCC_COMMUNITY_EDITION MATCHES "TRUE")
    set(CGM_LDFLAGS "${CGM_LDFLAGS} -L@OCC_DIR@/lib/oce-${OCC_VERSION}")
  endif (OCC_COMMUNITY_EDITION MATCHES "TRUE")
endif(CGM_HAS_OCC MATCHES ON)

include("${CMAKE_CURRENT_LIST_DIR}/CGMTargets.cmake")

set(CGM_INCLUDES_STR "-I@prefix@/include -I@prefix@/include/cgm @CGM_EXT_INCLUDE@")
set(CGM_LIBRARIES_STR
  "-lcgm @CGM_EXT_LIBS@"
)

include("${CMAKE_CURRENT_LIST_DIR}/ResolveCompilerPaths.cmake")

RESOLVE_LIBRARIES(CGM_LIBRARIES ${CGM_LIBRARIES_STR})
RESOLVE_INCLUDES(CGM_INCLUDES ${CGM_INCLUDES_STR})

